package com.hys.ultrasound.business.activity.ui.home;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.blankj.utilcode.util.ToastUtils;
import com.hys.ultrasound.R;
import com.hys.ultrasound.base.ui.BaseFragment;
import com.hys.ultrasound.business.activity.CreateArchiveActivity;

import butterknife.BindView;
/**
 * @desc:首页
 * @date:2020/10/14 14:56
 * @auther:lp
 * @version:0.0.1
 */
public class HomeFragment extends BaseFragment implements View.OnClickListener {
    @BindView(R.id.btnRemoteReading)
    Button mBtnRemoteReading;
    @BindView(R.id.btnTryFree)
    Button mBtnTryFree;

    @Override
    protected int getLayoutResId() {
        return R.layout.fragment_home;
    }

    @Override
    public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);

        num = 1;
        mBtnRemoteReading.setOnClickListener(this);
        mBtnTryFree.setOnClickListener(this);
    }

    @Override
    public void onClick(View view) {
        switch (view.getId()){
            case R.id.btnRemoteReading://远程阅片
                startActivity(new Intent(getActivity(), CreateArchiveActivity.class));
                break;
            default://免费试一试
                ToastUtils.showShort("跳转到超声扫描界面");
                break;
        }
    }
}